<?php

/*
 * To change this template, choose Tools | Templates
 * and open the template in the editor.
 */

/**
 * Description of users_m
 *
 * @author Topcarevn
 */
class users_m extends CI_Model {
    //put your code here
    public function __construct() {
        parent::__construct();
        $this->load->database();
    }
    
    function get_users($level = FALSE){
        $this->db->select("*");
        $this->db->from("members");
        if($level){
            $this->db->where("level",$level);
        }
        $data = $this->db->get();
        return $data->result_array();
    }
}

?>
